package com.chenlil.teamcity.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author chenlil
 * @DATE 2019/1/10 17:09
 **/
@RequestMapping("/hello")
@RestController
public class HelloController {
    @GetMapping("/getHello/{name}")
    public String getHello(@PathVariable("name")String name){
        return "hell"+name;
    }

    @GetMapping("/getHello/{name}/{age}")
    public String getHello(@PathVariable("name")String name,@PathVariable("age")String age){
        return "hell"+name+"----->"+age;
    }
}
